package im.zhihao.zhdisk.module.user.model.request;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;
import im.zhihao.zhdisk.module.filter.model.enums.FilterConfigHiddenModeEnum;
import im.zhihao.zhdisk.module.user.model.entity.SystemUser;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;
import java.util.Date;

@Data
@ApiModel(description = "新增用户请求参数类")
public class AddUserRequest {

    @ApiModelProperty(value = "用户名", required = true, example = "admin")
    @NotBlank(message = "用户名不能为空")
    private String username;


    @ApiModelProperty(value = "昵称", required = true, example = "超级管理员")
    @NotBlank(message = "昵称不能为空")
    private String nickname;

    @TableField(value = "password")
    @ApiModelProperty(value = "密码", required = true, example = "admin123")
    @Size(min = 6,message = "密码长度不得低于6位")
//    @Pattern(regexp = "^(?=.*[A-Z])(?=.*[a-z])(?=.*\\d)(?=.*[@#$%^&+=!])[^\\s]{8,}$",
//            message = "密码必须包含大写字母、小写字母、数字和特殊字符")
    private String password;

}
